<%@ Control Language="C#" AutoEventWireup="true" CodeFile="PreviewForm16.ascx.cs" Inherits="MyCustomModules_PreviewForm16" EnableViewState="true"  %>

<portal:HeadingControl ID="heading" runat="server" Text="Preview Form 16" />

    <asp:UpdatePanel ID="UpdatePanelPersonal" UpdateMode="Conditional" runat="server">
    <ContentTemplate>

    <!-- PERSONAL DETAILS -->
    <div>
    List of uploaded documents&nbsp;&nbsp;
    <a href="<%=System.Configuration.ConfigurationManager.AppSettings.Get("ShowAllUploadsLink")%>">Show All</a><br /><br />
    </div>
    <asp:Panel ID="pnlPreviews" runat="server">
          
    </asp:Panel>
    <div style="overflow:auto">
        <asp:DataGrid ID="dgDocuments" runat="server" AutoGenerateColumns="false" GridLines="Vertical" Width="100%"  >
                <Columns>
                    <asp:TemplateColumn HeaderText="Year" HeaderStyle-Font-Bold="true" HeaderStyle-BackColor="lightgray" >
                        <ItemTemplate>
                            <asp:Label runat="server" Text='<%# Eval("DocYear") %>'></asp:Label>
                        </ItemTemplate>    
                    </asp:TemplateColumn>
                    <asp:TemplateColumn HeaderText="File" HeaderStyle-Font-Bold="true" HeaderStyle-BackColor="lightgray" >
                        <ItemTemplate>
                            <asp:HyperLink Target="_blank" ID="HyperLink1" runat="server" Text='<%# GetDocumentName(Eval("FilePath")) %>' NavigateUrl='<%#GetDocumentLink(Eval("FilePath")) %>'></asp:HyperLink>
                        </ItemTemplate>    
                    </asp:TemplateColumn>
                </Columns>
            </asp:DataGrid>
    </div>

    </ContentTemplate>
    </asp:UpdatePanel>

